package com.example.model;

import lombok.Data;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * Description:方便后端响应翻页的数据
 * User: bjc
 * Date: 2025-07-23
 * Time: 22:20
 */
@Data
public class PageResult<T> {

    //返回查询的当前页的图书列表
    private List<T> bookInfoList;
    //返回总记录数
    private Integer totalCount;
    private  PageRequest pageRequest;//方便传入分页插件所需要的参数

    //构造方法
    public PageResult(List<T> bookInfoList, Integer totalCount, PageRequest pageRequest) {
        this.bookInfoList = bookInfoList;
        this.totalCount = totalCount;
        this.pageRequest = pageRequest;
    }

}
